<header class="am-topbar" style="background-color:gray;">
    <button class="am-topbar-btn am-topbar-toggle am-btn am-btn-sm am-btn-success am-show-sm-only"
            data-am-collapse="{target: '#doc-topbar-collapse'}"><span class="am-sr-only">导航切换</span> <span
            class="am-icon-bars"></span></button>

    <div class="am-collapse am-topbar-collapse" id="doc-topbar-collapse">
        <ul class="am-nav am-nav-pills am-topbar-nav">
            <li><a href="/my_blog/?user={{ blog_author_id }}"><font color="orange">他的文章</font></a></li>
            <li><a href="/my_blog/user_info/{{ blog_author_id }}"><font color="orange">关于他</font></a></li>

        </ul>
        <form method="GET" class="am-topbar-form am-topbar-left am-form-inline" action="/sharer_blog/search/"
              role="search">
            <div class="am-form-group">
                <input type="text" name="search_input" class="am-form-field am-input-sm" placeholder="搜索">
            </div>
        </form>
        {% if obj.login %}
            <div class="am-topbar-right">
                <div class="am-u-sm-2" style="margin-right:20px;">
                    <div class="am-dropdown" data-am-dropdown>
                        <a href="#" class="am-dropdown-toggle am-comment-avatar">

                            {% if obj.session.head_img_url %}
                                <img src="{{ obj.session.head_img_url }}" alt="" class="am-comment-avatar" width="48"
                                     height="48"/></a>
                            {% else %}
                                <img src="/static/myblogs/blogimg_default.png" alt="" class="am-comment-avatar"
                                     width="48"
                                     height="48"/></a>
                            {% endif %}
                        <ul class="am-dropdown-content">
                            <li><a href="/my_blog/user_info/{{ blog_author_id }}">用户账号：{{ obj.session.email }}</a></li>
                            <li><a href="/account/backstage/">后台管理</a></li>
                            <li><a href="/account/logout/">退出</a></li>
                        </ul>
                    </div>
                </div>
            </div>
        {% endif %}
    </div>
</header>